<?php

// Add the swipe style sheet
$GLOBALS['TL_CSS'][] = 'assets/swipe/'. SWIPE .'/css/swipe.min.css||static';

?>

<script type="text/javascript" src="<?php echo TL_ASSETS_URL; ?>assets/swipe/<?php echo SWIPE; ?>/js/swipe.min.js"></script>
<script type="text/javascript">
  /* <![CDATA[ */
  (function($) {
    $(document).ready(function() {
      $('.ce_sliderStart').each(function(i, cte) {
        var s = $('.content-slider', cte)[0],
            c = s.className.split(' ')[1].split('_');
        new Swipe(s, {
          // Put custom options here
          'auto': parseInt(c[1]),
          'speed': parseInt(c[2]),
          'startSlide': parseInt(c[3]),
          'continuous': parseInt(c[4]),
          'menu': $('.slider-control', cte)[0]
        });
      });
    });
  })(jQuery);
  /* ]]> */
</script>
